import { request } from '@/utils/request'
import qs from 'qs'

export const getZiyin = () => {
  return request('car/querynewown.do', 'get')
}
export const getHaohua = () => {
  return request('car/querynewluxury.do', 'get')
}
export const getLian = () => {
  return request('car/querynewcheep.do', 'get')
}
export const getSuv = () => {
  return request('car/querynewsuv.do', 'get')
}
// 查询指定车辆详细信息
export const getGoodCar = data => {
  return request('car/querycarinfo.do', 'post', qs.stringify(data))
}
// 当前用户的车辆信息screen

export const getUserCar = data => {
  return request('car/querycurrentusercar.do', 'post', qs.stringify(data))
}
// 多条件筛选
export const getScreenCar = data => {
  return request('car/querycarmulti.do', 'post', qs.stringify(data))
}
// 个人车辆发布
export const publishUserCar = data => {
  return request('car/publishcar.do', 'post', qs.stringify(data))
}
// 预约自营车
export const orderBusiness = data => {
  return request('car/reservecar.do', 'post', qs.stringify(data))
}
// 搜索车辆
export const navSearch = data => {
  return request('search/cars.do', 'post', qs.stringify(data))
}
// 车辆图片上传
export const publishImge = data => {
  return request('car/sendimages.do', 'post', data, {
    'Content-Type': 'multipart/form-data; boundary=<calculated when request is sent>'
  })
}
// 回收车iang
export const recoveryCar = data => {
  return request('car/recyclecar.do', 'post', qs.stringify(data))
}
// 卖出
export const sellpersonalCar = data => {
  return request('car/sellpersonalcar.do', 'post', qs.stringify(data))
}
// 下架
export const removepersonalCar = data => {
  return request('car/removepersonalcar.do', 'post', qs.stringify(data))
}
// 取消预约
export const cancelReserve = data => {
  return request('car/cancelreserve.do', 'post', qs.stringify(data))
}
// 修改指定车辆
export const editPersonalCar = data => {
  return request('car/editpersonalcar.do', 'post', qs.stringify(data))
}


